<%@ page import="com.studentManagement.po.Student" %><%--
  Created by IntelliJ IDEA.
  User: Administrator
  Date: 2017/5/9 0009
  Time: 9:19
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>

    <script src="${pageContext.request.contextPath}/resources/js/jquery.min.js" type="text/javascript"></script>
    <link rel="stylesheet" href="${pageContext.request.contextPath}/resources/css/bootstrap.min.css">
    <script src="${pageContext.request.contextPath}/resources/js/bootstrap.min.js" type="text/javascript"></script>

    <link rel="stylesheet" href="${pageContext.request.contextPath}/resources/css/studentDetail.css" type="text/css">
    <script src="${pageContext.request.contextPath}/resources/js/studentDetail.js" type="text/javascript"></script>

</head>
<body>
<jsp:include page="/jsp/teacher/top.jsp"/>
<div class="container">
    <div class="row clearfix">
        <jsp:include page="/jsp/teacher/class/class_title.jsp"/>
        <% Student student= (Student) request.getSession().getAttribute("student");%>
        <div class="_div">
        <form action="/StudentServlet?action=modifyStudentDetail" method="post" enctype="multipart/form-data" class="bs-example bs-example-form"  >
            <input type="hidden" id="message" value="${message}"><%--把提交的结果放在隐藏域中，转给jquery--%>

            <div class="input-group ">
                <span class="input-group-addon">学号</span>
                <input type="text" name="student_id"  readonly="readonly" class="form-control" id="getStudent_id" value="${student.student_id}" >
            </div>
            <br>
            <div class="input-group ">
                <span class="input-group-addon">姓名</span>
                <input type="text" class="form-control"  name="student_name" value="${student.student_name}">
            </div>
            <br>
                <%--密码:--%> <input type="hidden" name="student_key"  value="${student.student_id}">
            <div class="input-group ">
                <span class="input-group-addon">性别</span>
                <select class="form-control" name="student_sex" id="student_sex" about="${student.student_sex}">
                    <option value="男">男</option>
                    <option value="女">女</option>
                </select>
            </div>
            <br>
            <div class="input-group ">
                <span class="input-group-addon">年龄</span>
                <input type="text" class="form-control"  name="student_age" value="${student.student_age}">
            </div>
            <br>
            <div class="input-group ">
                <span class="input-group-addon">状态</span>
                <select class="form-control" name="student_state" id="student_state" about="${student.student_state}">
                    <option value="1">在读</option>
                    <option value="2">休学</option>
                    <option value="3">退学</option>
                    <option value="4">毕业</option>
                </select>
            </div>
            <br>
            <div class="input-group ">
                <span class="input-group-addon">学分</span>
                <input type="text" class="form-control" name="student_credit"  value="${student.student_credit}">
            </div>
            <br>
            <div class="input-group ">
                <span class="input-group-addon">手机</span>
                <input type="text" class="form-control" name="student_phone"  value="${student.student_phone}" maxlength="13">
            </div>
            <br>
            <div class="input-group ">
                <span class="input-group-addon">地址</span>
                <input type="text" class="form-control" name="student_address"  value="${student.student_address}">
            </div>
            <br>
            <div class="input-group ">
                <span class="input-group-addon"> Q &nbspQ </span>
                <input type="text" class="form-control" name="student_qq"  value="${student.student_qq}">
            </div>
            <br>
            <div class="input-group">
                <span class="input-group-addon">民族</span>
                <input type="text" class="form-control" name="student_nation"  value="${student.student_nation}">
            </div>
            <br>
            <div class="input-group ">
                <span class="input-group-addon">宿舍</span>
                <select class="form-control" name="student_dormitory_id" id="student_dormitory_id" about="${student.student_dormitory_id}"></select>
            </div>
            <br>
            <div class="input-group ">
                <span class="input-group-addon">班级</span>
                <select class="form-control" name="student_class_id" id="student_class_id" about="${student.student_class_id}"></select>
            </div>
            <br>
            <div class="input-group ">
                <span class="input-group-addon">班级职位</span>
                <select class="form-control" name="student_duty" id="student_duty" about="${student.student_duty}">
                    <option value="班级成员">班级成员</option>
                    <option value="班长">班长</option>
                    <option value="副班长">副班长</option>
                    <option value="团支书">团支书</option>
                    <option value="学习委员">学习委员</option>
                    <option value="纪律委员">纪律委员</option>
                    <option value="生活委员">生活委员</option>
                    <option value="组宣委员">组宣委员</option>
                    <option value="心理委员">心理委员</option>
                    <option value="体育委员">体育委员</option>
                </select>
            </div>
            <br>
            <div class="input-group ">
                <span class="input-group-addon">入学年份</span>
                <input type="text" class="form-control" name="student_enter_year"  value="${student.student_enter_year}">
            </div>
            <div class="row">
                <div class="image col-sm-6 col-md-3"  style="position: relative;top:-700px; right: -350px; width: 120px;height: 120px">
                    <a href="${pageContext.request.contextPath}/resources/images/upload/${ student.student_image_Path==""||student.student_image_Path==null  ? 'default.jpg' : student.student_image_Path  }" target="_blank" class="thumbnail">
                        <img id="getStudentImg"  src="${pageContext.request.contextPath}/resources/images/upload/${ student.student_image_Path=="" ||student.student_image_Path==null ? 'default.jpg' : student.student_image_Path  }" style="display: inline-block;width: 120px;height: 120px;" alt="学生照片">
                    </a>
                    <input type="file" onchange="previewFile()" name="student_image_Path">
                </div>
            </div>

            <br>
            <input type="submit" value="修改" class="btn btn-primary margin-padding" style="position: relative;top:-100px;right: -100px">
        </form>
        </div>
    </div>
</div>
</body>
</html>
